﻿DKPMCvcEngine = {}

local prefix_version_check    = "DKPMCversion_check"
local prefix_send_version     = "DKPMCsendVersion"



function DKPMCvcEngine:VersionCheckEvent(event, prefix, message, channel, sender)
   
    if (event == "CHAT_MSG_ADDON" and  prefix == prefix_send_version and channel == "WHISPER") then
        DKPMC:Print(sender.." version: "..message)
    elseif (event == "CHAT_MSG_ADDON" and  prefix == prefix_version_check and channel == "GUILD") then 
		SendAddonMessage(prefix_send_version, GetAddOnMetadata("DKPManager_client", "Version"), "WHISPER" , sender)
	end
end

function DKPMCvcEngine:SendVersionCheckPulse()
    SendAddonMessage(prefix_version_check, "Version Check", "GUILD" , nil);
    DKPMC:Print("Version Check issued...");
end

